package com.dengyiming.common.client;

import com.dengyiming.common.dto.Item;
import com.dengyiming.common.dto.PageDTO;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestParam;
@Component
@FeignClient("itemservice")
public interface ItemClient {
    @GetMapping("/item/list")
    PageDTO<Item> itemList(@RequestParam("page") Integer page, @RequestParam("size") Integer size);

    @GetMapping("/item/{id}")
    Item itemById(@PathVariable Long id);
}
